<template>
  <div class="errPage-container">
    <el-row>
      <el-col :span="8">
        <h2>您没有权限</h2>
        <h2>请联系管理员</h2>
        <div>
          <el-button type="primary" round class="errorTip__return-home"><a href="">返回主页</a></el-button>
          <el-button type="primary" round class="errorTip__goback" @click="back">返回上一页</el-button>
        </div>
      </el-col>
      <el-col :span="16">
        <img class="img-401" src="@/assets/401_images/401.png" alt="401">
      </el-col>
    </el-row>
  </div>
</template>

<script>
export default {
  name: 'Page401',
  methods: {
    back() {
      if (this.$route.query.noGoBack) {
        this.$router.push({ path: '/dashboard' })
      } else {
        this.$router.go(-1)
      }
    }
  }
}
</script>

<style lang="scss" scoped>
  .errPage-container {
    width: 800px;
    max-width: 100%;
    margin: 100px auto;
    .img-401{
      width: 400px;
    }
  }
</style>
